package com.yzi.core.json
{
	public class JSON
	{
		public function JSON()
		{
			throw new Error("Static Class.");
		}
		
		static public function Encode($object:Object): String
		{
			var encoder:JSONEncoder = new JSONEncoder($object);
			
			return encoder.GetString();			
		}
		
		static public function Decode($string:String): *
		{
			var decoder:JSONDecoder = new JSONDecoder($string);
			
			return decoder.GetValue();
		}
	}
}